{{if $CurrentUser['id']}}

		<div class="ui-portlet">
			<ol class="breadcrumb">
			  <li><a href="/users/index"><i class="fa fa-home"></i>&nbsp;&nbsp;{{__('Personal Center')}}</a></li>
			  <li class="active">我的发票</li>
			</ol>
		</div>        
       <hr>
       
      <div class="alert alert-warning">
		<p style="font-weight:bold;">提示：</p>
			<ul>
				<li>因发票税务领用数有限，每次发票的金额需大于50元，不足可累计开票，请合理安排周期。</li>
       			<li>发票高于300元时免邮费，低于300元时快递到付。快递费也需要发票的请备注顺丰到付，隔日达18元。没有备注默认发百世汇通到付，到付8元，百世汇通不提供发票。</li>
			</ul>
       	<p style="font-weight:bold;">好消息：</p>
       		<ul>
				<li>购买金额满300元发票包邮（百世快递）。</li>
			</ul>
		<p style="font-weight:bold;">您收到的发票可能由以下单位其中之一开具：</p>
       		<ul>
				<li>提子科技北京有限公司</li>				
				<li>成都刻尚科技有限公司</li>
				<li>湖南紫苏云信息科技有限公司</li>
			</ul>
       </div>
       <div class="mb10">
       		<a class="btn btn-primary" href="/order_invoices/add">发票申请</a>
       </div>
       <br/>
       
       <div class=" ui-portlet" id="OrderInvoice-mine-list">
	       <div class="row">
	       {{loop $datalist $k $item}}
	       	<div class="col-md-4">
	       		<div class="appmsg article-msg clearfix" id="wx-msg-{{$item['OrderInvoice']['id']}}"  data-creator="{{$item['OrderInvoice']['creator']}}"  data-id="{{$item['OrderInvoice']['id']}}">
		       		<div class="appmsg_content">
		       			
			       		<p class="title">
			       			{{$item['OrderInvoice']['name']}}  
			       		</p>
			       		<p class="title">
			       			<small>税号： {{$item['OrderInvoice']['ivc_nsrcode']}}  </small>
			       		</p>
			       		<hr style="margin:5px 0;">
			       		<p style="color:red;">￥{{$item['OrderInvoice']['invoice_value']}}</p>
			       		<small>
			       		<p style="font-weight:normal;font-size: 12px;">{{$item['OrderInvoice']['created']}}</p>
			       		<p>{{$item['OrderInvoice']['receiver']}} &nbsp; {{$item['OrderInvoice']['mobile']}}</p>
			       		<p>{{$item['OrderInvoice']['province']}} &nbsp; {{$item['OrderInvoice']['city']}} &nbsp; {{$item['OrderInvoice']['area']}}</p>
			       		<p><small>{{$item['OrderInvoice']['address']}}</small></p>
			       		
			       		{{if $item['OrderInvoice']['invoice_number']}}<p>发票号： {{$item['OrderInvoice']['invoice_number']}}</p>{{/if}}
			       		{{if $item['OrderInvoice']['courier_type']}}<p>快递类型： {{$item['OrderInvoice']['courier_type']}}</p>{{/if}}
			       		{{if $item['OrderInvoice']['courier_number']}}<p>快递单号： {{$item['OrderInvoice']['courier_number']}}</p>{{/if}}
			       		</small>

			       		<p>{{$item['OrderInvoice']['content']}}</p>
		       		</div>
		       		
		       		<div class="appmsg_opr clearfix" style="line-height: 44px;">
		       			{{if $item['OrderInvoice']['status'] == 0 }}		       			
		       				{{$this->Html->link('<i data-toggle="tooltip" target="_blank" data-container="body" data-placement="top" title="'.__('Edit').'" class="fa fa-edit"></i>', '/order_invoices/edit/'.$item['OrderInvoice']['id'],array('class'=>'col-xs-6 opr-edit','data-id'=>$item['OrderInvoice']['id'],'data-creator'=>$item['OrderInvoice']['creator'],'escape'=>false))}}
		       			{{/if}}
		       			{{if $item['OrderInvoice']['status'] <= 0 }}
		       				<a tabindex="0"  role="button" data-trigger="focus" href="javascript:void(0)" data-url="{{$this->Html->url('/order_invoices/delete/'.$item['OrderInvoice']['id'])}}" class="col-xs-6 delete-pop" data-content="确定删除此发票申请。"><i title="{{__('Delete')}}" class="fa fa-remove showtooltip"></i></a>   
		       			{{/if}}

		       			{{if $item['OrderInvoice']['status'] == 1 }} 
		       				已受理
		       			{{elseif $item['OrderInvoice']['status'] == 2 }} 
		       				已开具
		       			{{elseif $item['OrderInvoice']['status'] == 3 }} 
		       				已快递
		       			{{/if}} 			
		       		</div>
		       		
	       		</div>
	       	</div>
	       	
	       	{{if $k%3 == 2}} <div class="clearfix"></div> {{/if}}
	       	
	       	
	  		{{/loop}}
	    	</div>
    	{{$page_navi}}
    	
    	</div>
{{else}}
<div class="container">
 	<div class=" ui-portlet" id="OrderInvoice-mine-list">	您还没有登录，请<a href="/users/login" onclick="return checkLogin();">登录</a>后查看。</div>
</div>
{{/if}}
    	
